import request from '@/utils/request'

/**
 * 设置系统名称/主题色
 */
export function setDataByType(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sys/sysConfig/updateByName',
    method: 'post',
    data
  })
}

/**
 * 获取系统名称/主题色
 */
export function getDataByType(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sys/sysConfig/getByName',
    method: 'post',
    data
  })
}

/**
 * 获取企业信息
 */
export function getEnterpriseInfo(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/getEnterpriseInfo',
    method: 'post',
    data
  })
}

// 添加特殊配置
export function sysDesensitizationConfigInseter(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sysDesensitizationConfig/insert',
    method: 'post',
    data
  })
}
// 查询特殊配置页面
export function sysDesensitizationConfigQueryPage(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sysDesensitizationConfig/queryPage',
    method: 'post',
    data
  })
}
// 修改状态
export function sysDesensitizationConfigUpdate(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sysDesensitizationConfig/update',
    method: 'post',
    data
  })
}
// /  删除
export function sysDesensitizationConfigDelete(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: 'backend/sysDesensitizationConfig/deleteById',
    method: 'post',
    data
  })
}
// 修改特殊配置
export function sysDesensitizationConfiguUpdateStatus(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sysDesensitizationConfig/updateStatus',
    method: 'post',
    data
  })
}
// 获取系统配置
export function getConfig(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sys/sysConfig/getByName',
    method: 'post',
    data
  })
}
// 模块配置保存
export function save(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sys/sysConfig/updateByName',
    method: 'post',
    data
  })
}

// 获取字典
export function getDic(data) {
  return request({
    baseURL: '/API-ENTERPRISE-BACKEND/',
    url: '/backend/sysDictionary/getDictByCode',
    method: 'post',
    data
  })
}
